1. Field of the Invention
The present invention relates to a method and apparatus for forming a multiple focus stack image.
2. Description of the Related Art
There are many situations wherein an image scanning apparatus is used to obtain an image of a target. For example, in medical applications images of biological samples are often required. Such images are typically obtained using a microscope and digital image sensor.
One problem that occurs when generating an image of a target is that often the depth of focus provided by the optical arrangement of the apparatus is less than the variation in the height of the target to scan. For example, when using a 40× lens with a numerical aperture of 0.65, the depth of focus is around 1 micrometer. A typical microscope slide is not manufactured to hold this sort of tolerance and when mounted the slide may flex in access of one micrometer due to the mounting method or the forces of gravity. Additionally the sample being imaged may not itself be flat to one micrometer.
Within the art there are a number of methods to overcome this problem. In certain systems a focus map is generated using an image sensor during an initial scan of the target to be captured. This focus map is then used to adjust the focus of the imaging system whilst the final detailed image of the sample is obtained. This method generates problems in that it requires the building of a focus map for each sample, which is typically a time-consuming process.
An alternative method to address the above problem is to use multiple image scans at different focus levels. This is called focus stacking or z-stacking. A stack of z images are generated at z-focus positions using one or more image sensors and these images are then combined at a later date to give a single in-focus image. Suitable software for combining such images can be obtained from a number of suppliers.
European Patent Publication No. 1610166 provides a method and apparatus for generating such a multiple focus stack image. This publication teaches the use of a one-dimensional linear array as shown in FIG. 1A. The array 1 is moved in a direction of traverse 10 across the target and during this scanning motion a number of images at a number of different focus positions are generated. Typically, as the array 1 is moved in the direction of traverse 10, a lens assembly is moved to capture an image at each focus position.
The scanning motion performed by such a lens assembly is illustrated schematically in FIGS. 2A and 2B. To generate a final image at a selected focus position a number of scan lines are captured by the array 1. In FIG. 2A a first image at a first focus position is generated from scan lines 1,4,7,10, etc; a second image at a second focus position is generated from scan lines 2,5,8,11, etc.; and a third image at a third focus position is generated from scan lines 3,6,9,12 etc. The motion illustrated in FIG. 2A begins with the capture of a scan line 1. The lens assembly is then moved in order to alter the focus position. In the case of FIG. 2A, the lens assembly is held static in the direction of traverse 10 and is then moved perpendicular to the traverse direction so that scan line 2 can be captured. After the capture of scan line 2, the lens assembly is then further moved to the third focus position to scan line 3 while holding the array 1 static in the direction of traverse 10. After the capture of scan line 3 the array 1 is moved in the direction of traverse 10 and the lens assembly performs what is called a “flyback” movement, wherein the lens assembly moves from the third focus position to the first focus position. The lens assembly and array 1 are then in a position to capture a subsequent set of scan lines (4,5,6) at the three different focus positions. This process then continues until the total length of the target has been traversed.
The movement used to generate the sequence of FIG. 2A is shown in FIG. 3A. The X-axis represents the direction of traverse and the Z-axis represents the direction of movement of the lens assembly that enables a change in the focus position. The complete movement of the lens assembly thus comprises movement 31 and flyback movement 32.
Two variations on the method of scan line generation shown in FIG. 2A are shown in FIGS. 2B and 2C. In both FIGS. 2B and 2C after each scan line has been captured, the array 1 is moved a set distance in the direction of traverse 10. Typically this distance is equal to the width of the one-dimensional sensor array 1. After scan line 3 at the third focus position has been captured, the lens assembly again performs a flyback movement back to the first focus position in order to be ready to generate scan line 4 at the first focus position. In FIG. 2B, the flyback movement also involves a movement in a direction that is opposite to direction of traverse as shown in FIG. 3B, i.e. scan line 4 is aligned with scan line 2 in the direction of traverse. As can be seen in FIG. 2B, this process is repeated along the direction of traverse to produce the complete movement of the lens assembly shown in FIG. 3B. In FIG. 2C the flyback motion involves a rapid motion in the direction of traverse 10, and the scanning motion is repeated. Again, in both cases, the movement of the lens assembly comprises a scanning movement 31 and a flyback movement 32.
One problem that occurs with such a scanning motion is that large accelerations are required for the flyback motion. These large accelerations can produce unwanted and destructive forces within the mechanisms responsible for obtaining the different focus positions and their associated mountings and can also lead to jitter aberrations in a resultant image. This becomes especially problematic when the flyback motion involves a movement in the direction opposite to the direction of traverse, as the accelerations are applied in a direction opposite to the normal scanning direction.
Thus there is required a solution to the problem of efficiently generating a multiple focus stacked image without applying unwanted forces to the electrical and/or mechanical assemblies responsible for obtaining a number of different focus positions.